# https://leetcode-cn.com/problems/heaters/
# 475. 供暖器
from typing import List


class Solution:
    def findRadius(self, houses: List[int], heaters: List[int]) -> int:
        houses.sort()
        n_house = len(houses)
        n_heater = len(heaters)

        left_d = right_d = 0

        for i in range(n_heater):
            left_d = heaters[i] - 1
            right_d = heaters[i] + 1

